<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">

<html>
<head>
	<title>INPUT Type=Image: Browser Peculiarities: Linefeed and CR handling in ALT/title text</title>
<style>
.assert { color: green }
</style>
</head>

<body>

<big><b><u>Assertion:</u></b></big>
<div class="assert">Linefeed and Carriage Return handling (&#10; and &#13; respectively) 
for the ALT attribute:
<ul>
    <li>Internet Explorer: All literal/unencoded or encoded CR/LFs are maintained and displayed as intended.
    <li>Netscape: All unencoded or encoded CR/LFs are collapsed to nothing in ALT display (not the normal method for spacing-character collapsing - usually it would collapse to a single space.)
    <li>Opera: When the SRC attribute is unavailable, ALT contents are displayed; 
        unencoded CR/LFs are collapsed to a single space, while Encoded entities 
        are honored and displayed as intended.
</ul></div>
<br>

<form>
<b>Input Type=Image (right.gif); TITLE text is null string:</b>
<hr>
filler text 
<input type=image src="../../../objects/images/right.gif" alt="" title="">
filler text
<hr>
</form>
<br>

<form>
<b>Input Type=Image (right.gif); TITLE text is simple string ("title test"):</b>
<hr>
filler text 
<input type=image src="../../../objects/images/right.gif" alt="alt test" title="title test">
filler text
<hr>
</form>
<br>

<form>
<b>Input Type=Image (right.gif); TITLE text contains multiple character entities 
("&amp;ntilde;&amp;iuml;&amp;ccedil;&amp;ecirc; title test"):</b>
<hr>
filler text 
<input type=image src="../../../objects/images/right.gif" alt="&ntilde;&iuml;&ccedil;&ecirc; alt test" 
title="&ntilde;&iuml;&ccedil;&ecirc; title test">
filler text
<hr>
</form>
<br>

<form>
<b>Input Type=Image (right.gif); TITLE text contains multiple consecutive unencoded spaces. "this is a title test"
has 5 leading and trailing spaces, as well as 5 spaces between "is" and "a":</b>
<hr>
filler text 
<input type=image src="../../../objects/images/right.gif" alt="     this is     a alt test     " 
title="     this is     a title test     ">
filler text
<hr>
</form>
<br>

<form>
<b>Input Type=Image (right.gif); TITLE text contains multiple consecutive encoded spaces (&amp;nbsp;). 
"this is a title test" has 5 leading and trailing nbsp spaces, as well as 5 nbsp 
spaces between "is" and "a":</b>
<hr>
filler text 
<input type=image src="../../../objects/images/right.gif" 
alt="&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;this is&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;a alt test&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;" 
title="&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;this is&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;a title test&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;">
filler text
<hr>
</form>
<br>

<form>
<b>Input Type=Image (right.gif); TITLE text ("this is a title test") contains unencoded CR/LF 
between "this" and "is", as well as between "title" and "test":</b>
<hr>
filler text 
<input type=image src="../../../objects/images/right.gif" 
alt="this
is a alt
test" 
title="this
is a title
test">
filler text
<hr>
</form>
<br>

<form>
<b>Input Type=Image (right.gif); TITLE text ("this is a title test") contains encoded CR/LF (&amp;#10;/&amp;#13;)
between "this" and "is", as well as between "title" and "test":</b>
<hr>
filler text 
<input type=image src="../../../objects/images/right.gif" 
alt="this&#10;&#13;is a alt&#10;&#13;test" 
title="this&#10;&#13;is a title&#10;&#13;test">
filler text
<hr>
</form>
<br>

</body>
</html>
